const http = require('../utils/http.js');

// 砍价商品列表
const getBargainList = (data) => {
    return http.request('GET', '/bargain/bargain_list', data, true)
}

// 砍价商品详情
const getBargainDetails = (data) => {
    return http.request('GET', '/bargain/bargain_details', data, true)
}

// 获取当前商品详情我参团的信息
const getUserDetails = (data) => {
    return http.request('GET', '/bargain/user_details', data, true)
}

// 创建砍价订单
const createBargainOrder = (data) => {
    console.log(data);
    return http.request('POST', '/bargain/bargain_order', data, true)
}

module.exports = {
    getBargainList,
    getBargainDetails,
    getUserDetails,
    createBargainOrder
}